<template>
  <van-sticky>
    <!-- 搜索栏 -->
    <van-search
      v-model="value"
      placeholder="请输入搜索关键词"
      show-action
      shape="round"
      background="#ffd84d"
      input-align="center"
      @search="onSearch"
    >
      <div slot="action" @click="onSearch">搜索</div>
    </van-search>
  </van-sticky>
</template>

<script>
  import Vue from 'vue';
  import { Search} from 'vant';
  import { Sticky } from 'vant';

  Vue.use(Sticky);
  Vue.use(Search);
  export default{
    name:'Search',
    data(){
      return{
        value:'',
      }
    },
    methods:{
      onSearch(){

      },
      onCancel(){

      }
    }
  }
</script>

<style scoped="scoped">
  .home-search{
    background-color: #ffd84d;
  }
</style>
